import { post, setAccessToken, get } from "./base"

export const login = async (params)=>{
	const response = await post('mini/login', params)
	setAccessToken(response.token)
	return response
}

export const updateUser = async (params)=>{
	return await post('mini/userInfo', params)
}

export const getUserInfo = async ()=>{
	const resp = await get('user/getUserInfo', {})
	console.log('user/getUserInfo', resp)
	return resp
}